﻿#pragma once

#include "../MirObjects/NPC/NPCScript.h"
#include <string>
#include <vector>
#include <optional>

using namespace Server::MirObjects;

namespace Server::MirEnvir
{
    class Robot
    {
    public:
        std::optional<int> Month;
        std::optional<int> Day;
        std::optional<int> Hour;
        std::optional<int> Minute;
        std::optional<DayOfWeek> DayOfWeek;
    private:
        std::string Page;

        static bool CheckHour;
        static bool CheckMinute;
        static DateTime NextCheck;
//C# TO C++ CONVERTER WARNING: C++ has no equivalent to a 'readonly' collection which allows modification of internal state:
//ORIGINAL LINE: private static readonly List<Robot> Robots = new List<Robot>();
        static std::vector<Robot*> Robots;

        static void SetNextCheck();

        bool IsMatch(DateTime date);

    public:
        static void Process(NPCScript *script);

        static void AddRobot(const std::string &page);
    };
}
